<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html  xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org">
<head>
    <title>商城首页</title>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">
    <meta name="description" content="Write an awesome description for your new site here. You can edit this line in _config.yml. It will appear in your document head meta (for Google search results) and in your feed.xml site description.
">
    <link rel="stylesheet" href="lib/weui.min.css">
    <link rel="stylesheet" href="css/jquery-weui.css">
    <link rel="stylesheet" href="css/style.css">
    <style>
        .lb_img{
            width:375px;
            height: 175.775px;
        }
        .jinxun_name{
            font-size: 12px;
            color: black;
            font-weight: bold;
            text-align: center;
        }
        .jinxun_price{
            font-size:6px ;
            color:gray;
            text-align: center;
        }
        .tuijian_ceng{
            width:123.662px;
            height: 136.325px;
            background-color: white;
        }
        .jinxun_img{
            height:101.925px;
            width: 123.662px;
        }

    </style>
</head>
<body ontouchstart>
<!--顶部搜索-->
<header class='weui-header'>
    <div class="weui-search-bar" id="searchBar">
        <form class="weui-search-bar__form" action="goods_list.htm" method="post">
            <div class="weui-search-bar__box">
                <i class="weui-icon-search"></i>
                <input type="search" class="weui-search-bar__input" id="searchInput" name="searchname" list="prolist" placeholder="搜索您想要的商品" required>
                <a href="javascript:" class="weui-icon-clear" id="searchClear"></a>
            </div>
            <label class="weui-search-bar__label" id="searchText" style="transform-origin: 0px 0px 0px; opacity: 1; transform: scale(1, 1);">
                <i class="weui-icon-search"></i>
                <span>搜索您想要的商品</span>
            </label>
        </form>
        <a href="javascript:" class="weui-search-bar__cancel-btn" id="searchCancel">取消</a>
    </div>
</header>
<!--主体-->
<div class='weui-content'>
    <!--顶部轮播-->
    <div class="swiper-container swiper-banner">
        <div class="swiper-wrapper">
            <div class="swiper-slide" th:each="img:${listpl}">
                <a th:href="@{/pro_info.htm(goodsId=${img.goodsId})}">
                    <img th:src="${img.path}"  class="lb_img"/>
                </a>
            </div>
        </div>
        <div class="swiper-pagination"></div>
    </div>
    <!--图标分类-->
    <div class="weui-flex wy-iconlist-box">
        <div class="weui-flex__item"><a href="pro_list.html" class="wy-links-iconlist"><div class="img"><img src="../images/icon-link1.png"></div><p>精选推荐</p></a></div>
        <div class="weui-flex__item"><a href="goods_list_js.htm" class="wy-links-iconlist"><div class="img"><img src="../images/icon-link2.png"></div><p>酒水专场</p></a></div>
        <!--订单管理-->
        <div class="weui-flex__item" th:if="${session.user!=null}">
            <a href="show_order.htm" class="wy-links-iconlist">
                <div class="img">
                    <img src="../images/icon-link3.png">
                </div>
                <p>订单管理</p>
            </a>
        </div>
        <div class="weui-flex__item" th:if="${session.user==null}">
            <a href="login.htm" class="wy-links-iconlist">
                <div class="img">
                    <img src="../images/icon-link3.png">
                </div>
                <p>订单管理</p>
            </a>
        </div>
        <!--店铺管理-->
        <div class="weui-flex__item" th:if="${session.user!=null}">
            <a href="storein.htm"  class="wy-links-iconlist" th:if="${#lists.isEmpty(session.user.storeid)}">
                <div class="img">
                    <img src="../images/icon-link4.png">
                </div>
                <p>商家入驻</p>
            </a>
            <a href="storeinto.htm" class="wy-links-iconlist" th:if="${not #lists.isEmpty(session.user.storeid)}">
                <div class="img">
                    <img src="../images/icon-link6.png">
                </div>
                <p>店铺管理</p>
            </a>
        </div>
        <div class="weui-flex__item" th:if="${session.user==null}">
            <a href="login.htm"  class="wy-links-iconlist">
                <div class="img">
                    <img src="../images/icon-link4.png">
                </div>
                <p>商家入驻</p>
            </a>
        </div>
    </div>
    <!--新闻切换-->
    <div class="wy-ind-news">
        <i class="news-icon-laba"></i>
        <div class="swiper-container swiper-news">
            <div class="swiper-wrapper">
                <div class="swiper-slide"><a href="news_info.html">热烈祝贺Justbuy商城成功上线热烈祝贺Justbuy商城成功上线热烈祝贺Justbuy商城成功上线</a></div>
                <div class="swiper-slide"><a href="news_info.html">蓝之蓝股份成公司上市</a></div>
            </div>
            <div class="swiper-pagination"></div>
        </div>
        <a href="news_list.html" class="newsmore"><i class="news-icon-more"></i></a>
    </div>
    <!--精选推荐-->
    <div class="wy-Module">
        <div class="wy-Module-tit"><span>精选推荐</span></div>
        <div class="wy-Module-con">
            <div class="swiper-container swiper-jingxuan" style="padding-top:34px;">
                <div class="swiper-wrapper">
                    <div class="swiper-slide tuijian_ceng" th:each="jinx:${listrd}">
                        <a th:href="@{/pro_info.htm(goodsId=${jinx.goodsId})}">
                            <p class="jinxun_name" th:text="${jinx.RecommendContent}"></p>
                            <p class="jinxun_price" th:text="'￥'+${jinx.gd.price}"></p>
                            <img th:src="${jinx.path}" class="jinxun_img"/>
                        </a>
                    </div>
                </div>
                <div class="swiper-pagination jingxuan-pagination"></div>
            </div>
        </div>
    </div>
    <!--酒水专场-->
    <div class="wy-Module">
        <div class="wy-Module-tit"><span>酒水推荐</span></div>
        <div class="wy-Module-con">
            <div class="swiper-container swiper-jiushui" style="padding-top:34px;">
                <div class="swiper-wrapper">
                    <div class="swiper-slide tuijian_ceng" th:each="jstuij:${listrdbear}">
                        <a th:href="@{/pro_info.htm(goodsId=${jstuij.img.goodsId})}">
                            <p class="jinxun_name" th:text="${jstuij.img.RecommendContent}"></p>
                            <p class="jinxun_price" th:text="'￥'+${jstuij.price}"></p>
                            <img th:src="${jstuij.img.path}"  class="jinxun_img"/>
                        </a>
                    </div>
                </div>
                <div class="swiper-pagination jingxuan-pagination"></div>
            </div>
        </div>
    </div>
    <!--猜你喜欢-->
    <div class="wy-Module">
        <div class="wy-Module-tit-line"><span>猜你喜欢</span></div>
        <div class="wy-Module-con">
            <ul class="wy-pro-list clear">
                <li th:each="cnlove:${listgd}" class="love">
                    <a th:href="@{/pro_info.htm(goodsId=${cnlove.img.goodsId})}">
                        <div class="proimg"><img th:src="${cnlove.img.path}"></div>
                        <div class="protxt">
                            <div class="name" th:text="${cnlove.goodsName}"></div>
                            <div class="wy-pro-pri">¥<span th:text="${cnlove.price}"></span></div>
                        </div>
                    </a>
                </li>
            </ul>
            <div class="morelinks"><a href="javascript:more();">查看更多 >></a></div>
        </div>
    </div>
</div>

<!--底部导航-->
<div class="foot-black"></div>
<div class="weui-tabbar wy-foot-menu">
    <a href="/" class="weui-tabbar__item weui-bar__item--on">
        <div class="weui-tabbar__icon foot-menu-home"></div>
        <p class="weui-tabbar__label">首页</p>
    </a>
    <a href="kefu.htm" class="weui-tabbar__item"  th:if="${session.user!=null}">
        <div class="weui-tabbar__icon promotion-foot-menu-kefu"></div>
        <p class="weui-tabbar__label">客服</p>
    </a>
    <a href="login.htm" class="weui-tabbar__item" th:if="${session.user==null}">
        <div class="weui-tabbar__icon promotion-foot-menu-kefu"></div>
        <p class="weui-tabbar__label">客服</p>
    </a>
    <a href="show_all.htm" class="weui-tabbar__item" th:if="${session.user!=null}">
        <span th:if="${num!=null}"><span class="weui-badge" style="position: absolute;top: -.4em;right: 1em;"  th:text="${num}"></span></span>
        <div class="weui-tabbar__icon foot-menu-cart"></div>
        <p class="weui-tabbar__label">购物车</p>
    </a>
    <a href="login.htm" class="weui-tabbar__item" th:if="${session.user==null}">
        <div class="weui-tabbar__icon foot-menu-cart"></div>
        <p class="weui-tabbar__label">购物车</p>
    </a>
    <a href="myHome.htm" class="weui-tabbar__item">
        <div class="weui-tabbar__icon foot-menu-member"></div>
        <p class="weui-tabbar__label">我的</p>
    </a>
</div>

<!--<datalist id="prolist">-->
    <!--<option>111</option>-->
<!--</datalist>-->

<script src="lib/jquery-2.1.4.js"></script>
<script src="lib/fastclick.js"></script>
<script src="js/json2.js"></script>
<script>
    $(function() {
        FastClick.attach(document.body);
        $(".love:gt(5)").hide();
        $("#searchInput").bind('input propertychange',function(){
            var content=$(this).val();
            $.ajax({
                url:"searchlist.htm?content="+content,
                type:"post",
                success:function (message) {
                    $(".wy-foot-menu").after("<datalist id='prolist'></datalist>");
                    $.each(message,function(i,item){
                            $("#prolist").append("<option>"+item.goodsName+"</option>");
                    });
                }
            });
        })
    });
</script>
<script src="js/jquery-weui.js"></script>
<script src="js/swiper.js"></script>
<script>
    $(".swiper-banner").swiper({
        loop: true,
        autoplay: 3000
    });
    $(".swiper-news").swiper({
        loop: true,
        direction: 'vertical',
        paginationHide :true,
        autoplay: 30000
    });
    $(".swiper-jingxuan").swiper({
        pagination: '.swiper-pagination',
        loop: true,
        paginationType:'fraction',
        slidesPerView:3,
        paginationClickable: true,
        spaceBetween: 2
    });
    $(".swiper-jiushui").swiper({
        pagination: '.swiper-pagination',
        paginationType:'fraction',
        loop: true,
        slidesPerView:3,
        slidesPerColumn: 2,
        paginationClickable: true,
        spaceBetween:2
    });
</script>
<script type="text/javascript">
    function more() {
        $(".love:gt(5)").show();
        $(".morelinks").hide();
    }
</script>
</body>
</html>